package com.zyy.ui.enums;

/**
 * @EnumName: EnumForResultCode
 * @Description: 统一响应码
 * @Author: zyy
 * @Date: 2020/04/25 18:36
 * @Version: 1.0
 */
public enum EnumForResultCode {
    /*99999 一切ok*/
    SUCCESS("99999", "成功"),
    /*程序异常*/
    EXCEPTION("E00000", "程序异常，请联系开发~"),

    /*A0001-A9999 用户模块*/
    USER_NOT_LOGGED_IN("A0001", "用户未登录"),
    USER_LOGIN_ERROR("A0002", "用户名或者密码错误，请检查重试"),
    USER_ACCOUNT_FORBIDDEN("A0003", "账号已被禁用"),
    USER_HAS_EXISTED("A0004", "用户已存在"),

    /*B0001-B9999 参数校验*/
    ARGS_VALID_FAIL("B0001", "参数失败");

    private String resultCode;
    private String describe;

    EnumForResultCode(String resultCode, String describe) {
        this.resultCode = resultCode;
        this.describe = describe;
    }

    public String getResultCode() {
        return resultCode;
    }

    public String getDescribe() {
        return describe;
    }
}
